home *** CD-ROM | disk | FTP | other *** search
/ Amiga Developer CD 2.1 / Amiga Developer CD v2.1.iso / Reference / Includes_and_Autodocs_3.5 / include / clib / utility_protos.h < prev    next >
Encoding:
C/C++ Source or Header  |  1999-10-28  |  3.9 KB  |  120 lines

  1. #ifndef  CLIB_UTILITY_PROTOS_H
  2. #define  CLIB_UTILITY_PROTOS_H
  3.  
  4. /*
  5. **    $VER: utility_protos.h 40.1 (17.5.1996)
  6. **
  7. **    C prototypes. For use with 32 bit integers only.
  8. **
  9. **    Copyright © 1999 Amiga, Inc.
  10. **        All Rights Reserved
  11. */
  12.  
  13. #ifdef __cplusplus
  14. extern "C" {
  15. #endif /* __cplusplus */
  16.  
  17. #ifndef  EXEC_TYPES_H
  18. #include <exec/types.h>
  19. #endif
  20. #ifndef  EXEC_PORTS_H
  21. #include <exec/ports.h>
  22. #endif
  23. #ifndef  UTILITY_TAGITEM_H
  24. #include <utility/tagitem.h>
  25. #endif
  26. #ifndef  UTILITY_DATE_H
  27. #include <utility/date.h>
  28. #endif
  29. #ifndef  UTILITY_HOOKS_H
  30. #include <utility/hooks.h>
  31. #endif
  32. #ifndef  UTILITY_NAME_H
  33. #include <utility/name.h>
  34. #endif
  35. /*--- functions in V36 or higher (Release 2.0) ---*/
  36.  
  37. /* Tag item functions */
  38.  
  39. struct TagItem *FindTagItem( Tag tagVal, CONST struct TagItem *tagList );
  40. ULONG GetTagData( Tag tagValue, ULONG defaultVal, CONST struct TagItem *tagList );
  41. ULONG PackBoolTags( ULONG initialFlags, CONST struct TagItem *tagList, CONST struct TagItem *boolMap );
  42. struct TagItem *NextTagItem( struct TagItem **tagListPtr );
  43. VOID FilterTagChanges( struct TagItem *changeList, struct TagItem *originalList, ULONG apply );
  44. VOID MapTags( struct TagItem *tagList, CONST struct TagItem *mapList, ULONG mapType );
  45. struct TagItem *AllocateTagItems( ULONG numTags );
  46. struct TagItem *CloneTagItems( CONST struct TagItem *tagList );
  47. VOID FreeTagItems( struct TagItem *tagList );
  48. VOID RefreshTagItemClones( struct TagItem *clone, CONST struct TagItem *original );
  49. BOOL TagInArray( Tag tagValue, CONST Tag *tagArray );
  50. ULONG FilterTagItems( struct TagItem *tagList, CONST Tag *filterArray, ULONG logic );
  51.  
  52. /* Hook functions */
  53.  
  54. ULONG CallHookPkt( struct Hook *hook, APTR object, APTR paramPacket );
  55.  
  56. /* Date functions */
  57.  
  58. VOID Amiga2Date( ULONG seconds, struct ClockData *result );
  59. ULONG Date2Amiga( CONST struct ClockData *date );
  60. ULONG CheckDate( CONST struct ClockData *date );
  61.  
  62. /* 32 bit integer muliply functions */
  63.  
  64. LONG SMult32( LONG arg1, LONG arg2 );
  65. ULONG UMult32( ULONG arg1, ULONG arg2 );
  66.  
  67. /* 32 bit integer division funtions. The quotient and the remainder are */
  68. /* returned respectively in d0 and d1 */
  69.  
  70. LONG SDivMod32( LONG dividend, LONG divisor );
  71. ULONG UDivMod32( ULONG dividend, ULONG divisor );
  72. /*--- functions in V37 or higher (Release 2.04) ---*/
  73.  
  74. /* International string routines */
  75.  
  76. LONG Stricmp( CONST_STRPTR string1, CONST_STRPTR string2 );
  77. LONG Strnicmp( CONST_STRPTR string1, CONST_STRPTR string2, LONG length );
  78. UBYTE ToUpper( ULONG character );
  79. UBYTE ToLower( ULONG character );
  80. /*--- functions in V39 or higher (Release 3) ---*/
  81.  
  82. /* More tag Item functions */
  83.  
  84. VOID ApplyTagChanges( struct TagItem *list, CONST struct TagItem *changeList );
  85.  
  86. /* 64 bit integer muliply functions. The results are 64 bit quantities */
  87. /* returned in D0 and D1 */
  88.  
  89. LONG SMult64( LONG arg1, LONG arg2 );
  90. ULONG UMult64( ULONG arg1, ULONG arg2 );
  91.  
  92. /* Structure to Tag and Tag to Structure support routines */
  93.  
  94. ULONG PackStructureTags( APTR pack, CONST ULONG *packTable, CONST struct TagItem *tagList );
  95. ULONG UnpackStructureTags( CONST APTR pack, CONST ULONG *packTable, struct TagItem *tagList );
  96.  
  97. /* New, object-oriented NameSpaces */
  98.  
  99. BOOL AddNamedObject( struct NamedObject *nameSpace, struct NamedObject *object );
  100. struct NamedObject *AllocNamedObjectA( CONST_STRPTR name, CONST struct TagItem *tagList );
  101. struct NamedObject *AllocNamedObject( CONST_STRPTR name, Tag tag1, ... );
  102. LONG AttemptRemNamedObject( struct NamedObject *object );
  103. struct NamedObject *FindNamedObject( struct NamedObject *nameSpace, CONST_STRPTR name, struct NamedObject *lastObject );
  104. VOID FreeNamedObject( struct NamedObject *object );
  105. STRPTR NamedObjectName( struct NamedObject *object );
  106. VOID ReleaseNamedObject( struct NamedObject *object );
  107. VOID RemNamedObject( struct NamedObject *object, struct Message *message );
  108.  
  109. /* Unique ID generator */
  110.  
  111. ULONG GetUniqueID( VOID );
  112.  
  113.  
  114.  
  115. #ifdef __cplusplus
  116. }
  117. #endif /* __cplusplus */
  118.  
  119. #endif   /* CLIB_UTILITY_PROTOS_H */
  120.